🐛 Fetch the documentation URL dynamically#24
Conversation
becbe1e to
dfec882
Compare
dfec882 to
fb3ee8e
Compare
|
Do you think this is a good approach @tiangolo ? 🙏🏻 |
|
@tiangolo I do not have permission to configure a label for the PR. https://github.com/fastapi/fastapi-cli/actions/runs/10408815023/job/28827030912?pr=24 |
|
I ran across the same bug today and I can confirm that the provided patch resolves the issue. |
|
This pull request has a merge conflict that needs to be resolved. |
|
@chipytux , thank you for your interest and efforts! This PR needs to be updated to reflect latest changes. Would you like to work on this? |
|
Hi, this sounds interesting. Could you tell me more about what exactly needs to be done? |
|
oh, ok, I'm able to handle these changes since @chipytux isn't aware of it cc: @YuriiMotov |
|
I meant we need to resolve the merge conflicts (merge The |
|
I ended up not keeping up with the notifications for this pull request on GitHub, my apologies. I’m glad @pedroimpulcetto continued working on the solution in PR #221. I believe this will help some people access the Swagger page more quickly. I will close this pull request since the work will continue in PR #221. |
|
Thank you @chipytux for the original idea! |
Pull Request Description
Title: Fetch docs_url dynamically from FastAPI app
Description:
This pull request introduces a change to the
fastapi-clilibrary that fetches thedocs_urlvalue dynamically from the FastAPI application instead of using a hardcoded value.Implementation Details:
The change involves modifying the
_runfunction to fetch thedocs_urlvalue from the FastAPI application using theapp.openapi_urlattribute. This ensures that the library always uses the URL specified by the application itself.Testing:
The updated function has been thoroughly tested to ensure it correctly retrieves the
docs_urlvalue from the FastAPI application and show the appropriate URL.